home *** CD-ROM | disk | FTP | other *** search
- on getNextGroup
- global wagonList, wagonPos
- if count(wagonList) = 1 then
- set the castNum of sprite 13 to the number of cast "left wheel dark"
- set the castNum of sprite 14 to the number of cast "right wheel dark"
- set the castNum of sprite 5 to the number of cast getAt(wagonList, wagonPos)
- set the locV of sprite 6 to -100
- set the locV of sprite 7 to -100
- else
- if count(wagonList) = 2 then
- set the castNum of sprite 13 to the number of cast "left wheel dark"
- set the castNum of sprite 14 to the number of cast "right wheel dark"
- set the castNum of sprite 5 to the number of cast getAt(wagonList, wagonPos)
- set the castNum of sprite 6 to the number of cast getAt(wagonList, wagonPos + 1)
- set the locV of sprite 7 to -100
- else
- if count(wagonList) = 3 then
- set the castNum of sprite 13 to the number of cast "left wheel dark"
- set the castNum of sprite 14 to the number of cast "right wheel dark"
- set the castNum of sprite 5 to the number of cast getAt(wagonList, wagonPos)
- set the castNum of sprite 6 to the number of cast getAt(wagonList, wagonPos + 1)
- set the castNum of sprite 7 to the number of cast getAt(wagonList, wagonPos + 2)
- else
- repeat with u = 5 to 7
- set the castNum of sprite u to the number of cast getAt(wagonList, wagonPos)
- set wagonPos to wagonPos + 1
- if wagonPos > count(wagonList) then
- set wagonPos to 1
- end if
- end repeat
- end if
- end if
- end if
- updateStage()
- end
-
- on getPrevGroup
- global wagonList, wagonPos
- if count(wagonList) = 1 then
- set the castNum of sprite 13 to the number of cast "left wheel dark"
- set the castNum of sprite 14 to the number of cast "right wheel dark"
- set the castNum of sprite 5 to the number of cast getAt(wagonList, wagonPos)
- set the locV of sprite 7 to -100
- else
- if count(wagonList) = 2 then
- set the castNum of sprite 13 to the number of cast "left wheel dark"
- set the castNum of sprite 14 to the number of cast "right wheel dark"
- set the castNum of sprite 5 to the number of cast getAt(wagonList, wagonPos)
- set the castNum of sprite 6 to the number of cast getAt(wagonList, wagonPos + 1)
- set the locV of sprite 7 to -100
- else
- if count(wagonList) = 3 then
- set the castNum of sprite 13 to the number of cast "left wheel dark"
- set the castNum of sprite 14 to the number of cast "right wheel dark"
- set the castNum of sprite 5 to the number of cast getAt(wagonList, wagonPos)
- set the castNum of sprite 6 to the number of cast getAt(wagonList, wagonPos + 1)
- set the castNum of sprite 7 to the number of cast getAt(wagonList, wagonPos + 2)
- else
- repeat with u = 5 to 7
- set the castNum of sprite u to the number of cast getAt(wagonList, wagonPos)
- set wagonPos to wagonPos - 1
- if wagonPos < 1 then
- set wagonPos to count(wagonList)
- end if
- end repeat
- end if
- end if
- end if
- updateStage()
- end
-